<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <style>
    ul {
      list-style: none;
      font-size: 0.3rem;
      margin: 0;
      padding: 0;
    }

    div {
      width: 80%;
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
    }
    li {
      line-height: 2;
    }
  </style>
  <body>
    <div>
      <ul>
        <li>new Date("2024-02-05T00:00:00Z")打印的时间戳为（）；new Date("2024-02-05T00:00:00Z").getTime() 打印的时间戳为（）;new Date("2024-02-05T00:00:00")打印的时间戳为（）；new Date("2024-02-05T00:00:00").getTime() 打印的时间戳为（）</li>
      </ul>
    </div>
  </body>
  <script>
    function init() {
      var width = document.documentElement.clientWidth;
      document.documentElement.style.fontSize = width / 7.5 + "px";
    }
    init();
    window.addEventListener("orientationchange", init);
    window.addEventListener("resize", init);
  </script>
  <script>
    var targetTime1 = new Date("2024-02-05T00:00:00Z");
    var targetTime2 = new Date("2024-02-05T00:00:00Z").getTime();
    var targetTime3 = new Date("2024-02-05T00:00:00");
    var targetTime4 = new Date("2024-02-05T00:00:00").getTime();

    var ele = document.querySelector("ul li");
    ele.innerHTML = `new Date("2024-02-05T00:00:00Z")打印的时间戳为（${targetTime1}）；new Date("2024-02-05T00:00:00Z").getTime() 打印的时间戳为（${targetTime2}）
    new Date("2024-02-05T00:00:00")打印的时间戳为（${targetTime3}）；new Date("2024-02-05T00:00:00").getTime() 打印的时间戳为（${targetTime4}）`;
  </script>
</html>
